<?php
namespace Application\Api\Controller;

class WeiXinSpPay2 extends Base
{

    /*
        /Api/WeiXinSpPay2/getPay
    */
    public function getPayAction()
    {
        $openId = 'oRA4L4wg4IDABeIIn1w-Pe0OpnI0';
        $name = '测试';
        $orderNo = makeOrderNo(8, 0);
        $amount = 0.01;
        $result = $this->get(PAY_WEIXINSP)->getPay($openId, $name, $orderNo, $amount);
        $this->sendSuccess($result);
    }

    /*
        /Api/WeiXinSpPay2/queryPay
    */
    public function queryPayAction()
    {
        $orderNo = '1912302100440300000006324678';
        $result = $this->get(PAY_WEIXINSP)->queryPay($orderNo);
        $this->sendSuccess($result);
    }

}